<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <title>编辑用户</title>
  <meta name="renderer" content="webkit">
  <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
  <link rel="stylesheet" href="/layuiadmin/layui/css/layui.css" media="all">
  <style>
    @media screen and (min-width: 490px) {
      .layui-form-item .layui-input-inline {
        width: 70%;
      }
    }
  </style>
</head>
<body>

<div class="layui-form" lay-filter="layuiadmin-form-useradmin" id="layuiadmin-form-useradmin" style="padding: 20px 0 0 0;">
  <input type="hidden" name="uId" value="${user.uId}">
  <div class="layui-form-item">
    <label class="layui-form-label">用户名</label>
    <div class="layui-input-inline">
      <input type="text" name="uName" value="${user.uName}" lay-verify="required" placeholder="请输入用户名" maxlength="8" autocomplete="off" class="layui-input">
    </div>
  </div>
  <div class="layui-form-item">
    <label class="layui-form-label">手机号码</label>
    <div class="layui-input-inline">
      <input type="text" name="uTel"  value="${user.uTel}" lay-verify="phone" placeholder="请输入号码" autocomplete="off" class="layui-input">
    </div>
  </div>
  <div class="layui-form-item">
    <label class="layui-form-label">邮箱</label>
    <div class="layui-input-inline">
      <input type="text" name="uEmail"  value="${user.uEmail}" lay-verify="email" placeholder="请输入邮箱" autocomplete="off" class="layui-input">
    </div>
  </div>
  <div class="layui-form-item" lay-filter="sex">
    <label class="layui-form-label">性别</label>
    <div class="layui-input-block">
      <input type="radio" name="uSex" value="1" title="男" ${user.uSex==1?'checked':''}>
      <input type="radio" name="uSex" value="2" title="女" ${user.uSex==2?'checked':''}>
      <input type="radio" name="uSex" value="3" title="保密" ${user.uSex==3?'checked':''}>
    </div>
  </div>
  <div class="layui-form-item">
    <label class="layui-form-label">QQ登录</label>
    <div class="layui-input-inline">
      <input type="text" name="uQqid" value="${user.uQqid}" lay-verify="" maxlength="32" placeholder="QQ openID" autocomplete="off" class="layui-input">
    </div>
  </div>
  <div class="layui-form-item">
    <label class="layui-form-label">头像</label>
    <div class="layui-input-inline">
      <input type="text" name="uPic" value="${user.uPic}" lay-verify="required" maxlength="50" placeholder="头像文件名" autocomplete="off" class="layui-input">
    </div>
  </div>
  <div class="layui-form-item">
    <label class="layui-form-label">个人简介</label>
    <div class="layui-input-inline">
      <textarea  name="uIntroduction" style="height: 100px;" maxlength="255" autocomplete="off" class="layui-input">${user.uIntroduction}</textarea>
    </div>
  </div>
  <div class="layui-form-item">
    <label class="layui-form-label">最近登录</label>
    <div class="layui-input-inline">
      <input type="text" name="" value="${user.uIp}" style="border: 0px;" placeholder="未登录" disabled autocomplete="off" class="layui-input layui-disabled">
    </div>
  </div>
  <div class="layui-form-item layui-hide">
    <input type="button" lay-submit lay-filter="LAY-user-front-submit" id="LAY-user-front-submit" value="确认">
  </div>
</div>

<script src="/layuiadmin/layui/layui.js"></script>
<script>
    layui.config({
        base: '/layuiadmin/' //静态资源所在路径
    }).extend({
        index: 'lib/index' //主入口模块
    }).use(['index', 'form', 'upload'], function(){
        var $ = layui.$
            ,form = layui.form
            ,upload = layui.upload ;

        upload.render({
            elem: '#layuiadmin-upload-useradmin'
            ,url: layui.setter.base + 'json/upload/demo.js'
            ,accept: 'images'
            ,method: 'get'
            ,acceptMime: 'image/*'
            ,done: function(res){
                $(this.item).prev("div").children("input").val(res.data.src)
            }
        });
    })
</script>
</body>
</html>